//
// Copyright (c) 2011 Alex Nesterenko
//

#ifndef NANE_X11WINDOWSYSTEM_H
#   define  NANE_X11WINDOWSYSTEM_H

#   include "nane/WindowSystem/IWindowSystem.h"

#   include <X11/Xlib.h>

namespace nane
{
    class X11WindowSystem
        : public IWindowSystem
    {
    public:
        X11WindowSystem();
        ~X11WindowSystem();

        bool initialize();
        void shutdown();

    public:
        IWindow* createWindow( const char* _title, uint32 _width, uint32 _height, uint32 _posX, uint32 _posY );
        void releaseWindow( IWindow* _window );
        uint32 getScreenWidth();
        uint32 getScreenHeight();

    private:
        Display* m_display;
        int m_colorBlack;
        int m_colorWhite;
        Atom m_deleteWindowAtom;
    };
}   // namespace nane

#endif // NANE_X11WINDOWSYSTEM_H
